package lab02.test37;

/**
 * Created by AIR on 2017/11/13.
 */
public class StudentDemo {
    public static void main(String[] args) {
Student[] students=new Student[3];
students[0]= new Undergraduate();
students[0].name="小明";
students[0].type="本科生";
students[0].scores[0]=45;
students[0].scores[1]=78;
students[0].scores[2]=90;

students[1]=new Undergraduate();
students[1].name="小红";
students[1].type="本科生";
students[1].scores[0]=89;
students[1].scores[1]=90;
students[1].scores[2]=78;

students[2]=new Graduate();
students[2].name="程嘉星";
students[2].type="研究生";
students[2].scores[0]=90;
students[2].scores[1]=98;
students[2].scores[2]=99;

        System.out.println("姓名  类别  是否通过");
        for (int i=0;i<3;i++)
        System.out.println(students[i].name+students[i].type+students[i].calGrader());

    }
}
